{if $canCreateProject}
{form editForm}
<div style="float:left;width: 47%;" class="block" id="projectDetails">
	<h2>{if $form[id]->value == ''}Nový projekt{else}Upravit projekt: {$form[name]->value}{/if}</h2>
<table>
		{var $leftColumn = array('name','deadline','public','parent'=>'project_id','description','task_types','closed')}
		{foreach $leftColumn as $line}
	<tr><td>{label $line /}</td><td>{input $line}</td></tr>
		{/foreach}

</table>
</div>
<div style="float:right; width:47%" class="block" id="projectMembers">
	<div style="float:left; width: 50%">
		<h2>{label members /}</h2>
		<div id="memberlist">{input members}</div>
	</div>
	<div style="float:right;width: 50%">
		<div id="department_filter">
			<h2>Filtr dle oddělení:</h2>
			<div class="department_item"><input type="radio" class="department" id="department_none" value="-1" name="dep_filter" checked="checked"><label for="department_none"><em>Nevybráno</em></label></div>
		{foreach $departments as $department}
			<div class="department_item"><input type="radio" class="department" id="department_{$department[name]}" value="{$department[id]}" name="dep_filter"><label for="department_{$department[name]}">{$department[name]}</label></div>
		{/foreach}

		</div>
		<div id="skill_filter">
			<h2>Filtr dle dovedností:</h2>
		{foreach $skills as $skill}
			<div class="skill_item"><input type="checkbox" class="skill" id="skill_{$skill[name]}" value="{$skill[id]}"><label for="skill_{$skill[name]}">{$skill[name]}</label></div>
		{/foreach}
		</div>
	</div>

</div>
<div class="clear"></div>
<div class="block center">
	{ifset $edit}{input id}{/ifset}
	{input send}
</div>
<script type="text/javascript">
	var usersWithSkill = {$usersWithSkill};
	var usersInDepartment = {$usersInDepartment};
	var skillsInDepartment = {$skillsInDepartment};
</script>
<script type="text/javascript" src="{$basePath}/js/project.settings.js"></script>
{/form}
{else}
<div class="block">
	Nemáte práva k vytvoření / editaci projektu.
</div>
{/if}